package com.yy.micro.magic.core.domain;

import com.yy.micro.magic.exception.ExceptionManager;

import java.util.Map;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

@ApiModel(description = "魔方变换后的结果")
public class MagicResponse {
    @ApiModelProperty(notes ="魔方变换后的输出结果，Map" )
    private Map<String, Object> result;
    @ApiModelProperty(notes = "在变换过程中，如果遇到异常，则把所有的异常收集并返回")
    private ExceptionManager exceptionManager;

    public Map<String, Object> getResult() {
        return result;
    }

    public void setResult(final Map<String, Object> result) {
        this.result = result;
    }

    public ExceptionManager getExceptionManager() {
        return exceptionManager.isBlock()?exceptionManager:null;
    }

    public void setExceptionManager(final ExceptionManager exceptionManager) {
        this.exceptionManager = exceptionManager;
    }
}
